import { createSlice } from '@reduxjs/toolkit';

const initialState = {
    threadIsRefresh: false,
    userIsRefresh: false,
};

const active = createSlice({
    name: 'active',
    initialState,
    reducers: {
        setThreadIsRefresh: (state, action) => {
            state.threadIsRefresh = action.payload;
        },
        setUserIsRefresh: (state, action) => {
            state.userIsRefresh = action.payload;
        },
    },
});

export const { setThreadIsRefresh, setUserIsRefresh } = active.actions;
export default active.reducer;
